package com.chong.method;

public class Demo4 {
    /*
    可变参数
     */
    public static void main(String[] args) {
        Demo4  demo4 = new Demo4();
        demo4.test(1,1,2,1,36,5);
    }
    public void  test(int... i){
        System.out.println(i[0]);
        System.out.println(i[1]);
        System.out.println(i[2]);
        System.out.println(i[3]);
        System.out.println(i[4]);
        System.out.println(i[5]);
    }
}
